

{extend name="main/index" /}
{block name="main"}

<!-- Start right content -->
<div class="content-page">
    <!-- ============================================================== -->
    <!-- Start Content here -->
    <!-- ============================================================== -->
    <div class="content">
        <!-- Page Heading Start -->
        <div class="page-heading">
            <h1><i class='fa fa-table'></i> Tables</h1>
            <h3>Basic & Simple Sortable Tables</h3></div>
        <!-- Page Heading End-->                <!-- Your awesome content goes here -->


        <div class="row">
            <div class="col-md-12">
                <div class="widget">
                    <div class="widget-header transparent">
                        <h2><strong>Toolbar</strong> CRUD Table</h2>
                        <div class="additional-btn">
                            <a href="#" class="hidden reload"><i class="icon-ccw-1"></i></a>
                            <a href="#" class="widget-toggle"><i class="icon-down-open-2"></i></a>
                            <a href="#" class="widget-close"><i class="icon-cancel-3"></i></a>
                        </div>
                    </div>
                    <div class="widget-content">
                        <div class="data-table-toolbar">
                            <div class="row">
                                <form action="{:url('admin/node/index')}">
                                    <div class="col-md-4">
                                        <input type="text" name="nname" class="form-control" placeholder="节点名...">
                                    </div>
                                    <div class="col-md-2">
                                        <button class="btn btn-primary">search</button>
                                    </div>
                                </form>
                                <div class="col-md-8">
                                    <div class="toolbar-btn-action">
                                        <a class="btn btn-success"><i class="fa fa-plus-circle"></i> Add new</a>
                                        <a class="btn btn-danger"><i class="fa fa-trash-o"></i> Delete</a>
                                        <a class="btn btn-primary"><i class="fa fa-refresh"></i> Update</a>
                                    </div>
                                </div>
                            </div>
                        </div>

                        <div class="table-responsive">
                            <table data-sortable class="table table-hover table-striped">
                                <thead>
                                <tr>
                                    <th>ID</th>
                                    <th>节点名称</th>
                                    <th>模块名（控制器）</th>
                                    <th>操作</th>
                                    <th>状态</th>
                                    <th>操作</th>
                                </tr>
                                </thead>

                                <tbody>
                                {volist name="list" id="vo" key="k"}
                                <tr>
                                    <td>{$vo.id}</td>
                                    <td>{$vo.name}</td>
                                    <td>{$vo.mname}</td>
                                    <td>{$vo.aname}</td>
                                    <td>{if $vo.status == 1}启用{else /}禁用{/if}</td>
                                    <td>
                                        <a href="{:url('admin/node/delete', ['id'=>$vo['id']])}">删除</a>

                                        <a href="{:url('admin/node/edit', ['id'=>$vo['id']])}">修改</a>
                                    </td>

                                </tr>
                                {/volist}


                                </tbody>
                            </table>
                        </div>
                        {$page}
                        
                    </div>
                </div>
            </div>

        </div>

        <!-- Footer Start -->
        <footer>
            Huban Creative &copy; 2014
            <div class="footer-links pull-right">
                <a href="#">About</a><a href="#">Support</a><a href="#">Terms of Service</a><a href="#">Legal</a><a
                    href="#">Help</a><a href="#">Contact Us</a>
            </div>
        </footer>
        <!-- Footer End -->
    </div>
    <!-- ============================================================== -->
    <!-- End content here -->
    <!-- ============================================================== -->

</div>
<!-- End right content -->

{/block}

